<?php

	$id = $_GET['id'];

	if ($id == '1') {
		echo '<a data-val="1">1</a>';
	} else if ($id == '2') {
		echo '<a data-val="2">2</a>';
	} else if ($id == '3') {
		echo '<a data-val="3">3</a>';
	} else {
		echo '<a data-val="4">4</a>';
	}

	exit();
	echo "<pre>";

	$array = array(
		'sasdfas sdaf ',
		'a' => 'age',
		'n' => 'name', 
		'rrr34 34t3w ergdf'
	);
	foreach ($array as $key => $value) {
		echo gettype($key) . "<br>";
		echo ($array[$key]) . "<br>";
//		echo gettype($value) . "<br>";
		echo "<br>";
	}
	pr($array);

	die();





//	function auto_load($class){
//		echo __NAMESPACE__ . "<br />";
//		print_r($class);
//	}
//	spl_autoload_register('auto_load');
//
//
//$iterator = new DirectoryIterator('/');
//while($iterator->valid()) {
//    $file = $iterator->current();
//    echo $iterator->key() . " => " . $file->getFilename() . "\n";
//    $iterator->next();
//}
//exit();
//		App ID
//		1431277480433985
//		App Secret
//		e3171a8f5b955595b31e4b49142200b7

	include("system/library/PhptricksExceptions/PhptricksExceptions.php");
	include("system/library/facebook/facebook.php");
	use \Phptricks\system\library\facebook\facebook as facebook;
$facebook_loader = facebook::getinstance();
	$facebook_loader->use_library("HttpClients/FacebookHttpable");
	$facebook_loader->use_library("HttpClients/FacebookCurlHttpClient");
	$facebook_loader->use_library("HttpClients/FacebookCurl");
	$facebook_loader->use_library("GraphObject");
	$facebook_loader->use_library("GraphSessionInfo");
	$facebook_loader->use_library("Entities/AccessToken");
	$facebook_loader->use_library("FacebookResponse");
	$facebook_loader->use_library("FacebookRequest");
	$facebook_loader->use_library("FacebookSession");
	use Facebook\FacebookSession as Fb_Session;
Fb_Session::setDefaultApplication('1431277480433985', 'e3171a8f5b955595b31e4b49142200b7');
	$session = new Fb_Session('access-token');

// If you're making app-level requests:
	$session = Fb_Session::newAppSession();

// To validate the session:
	try {
		echo $session->validate() . "<br>";
		echo $session->getUserId() . "<br>";
		$request = new FacebookRequest(
				$session, 'GET', '/{user-id}/likes/{page-id}'
		);
		$response = $request->execute();
		$graphObject = $response->getGraphObject();
	} catch (FacebookRequestException $ex) {
		// Session not valid, Graph API returned an exception with the reason.
		echo $ex->getMessage();
	} catch (\Exception $ex) {
		// Graph API returned info, but it may mismatch the current app or have expired.
		echo $ex->getMessage();
	}
	echo "<pre>";
	print_r(\get_included_files());
	exit();
//	echo "<pre>";
//	$a = array('<foo>', "'bar'", '"baz"', '&blong&', "\xc3\xa9");
//
//	$normal = json_encode($a);
//	$tags = json_encode($a, JSON_HEX_TAG);
//
//	echo "Normal: ", $normal, "\n";
//	echo "Tags: ", $tags, "\n";
//
//
//	echo "Normal: ", print_r((object) json_decode($normal)), "\n";
//	echo "Tags: ", print_r((object) json_decode($tags)), "\n";

	function pr($str, $exitpage = 0){
		echo '<pre style=" direction: ltr; text-align: left; color:#000; ">';
		if ($exitpage == 0) {
			print_r($str);
		} else {
			print_r($str);
			exit();
		}
		echo '</pre>';
	}
	